from rest_framework import serializers

from.models import SysPost
from.models import SysConfig
from.models import SysDept
from.models import SysDictData
from.models import SysDictType
from.models import SysJob
from.models import SysJobLog
from.models import SysLogininfor
from.models import SysMenu
from.models import SysOperLog
from.models import SysRole
from.models import SysRoleDept
from.models import SysRoleMenu
from.models import SysUserPost


class SysConfigSerializer(serializers.ModelSerializer):
    ''' 系统配置序列化器 '''
    class Meta:
        model = SysConfig
        fields = '__all__'


class SysDeptSerializer(serializers.ModelSerializer):
    ''' 系统部门序列化器 '''
    class Meta:
        model = SysDept
        fields = '__all__'


class SysDictDataSerializer(serializers.ModelSerializer):
    ''' 系统字典数据序列化器 '''
    class Meta:
        model = SysDictData
        fields = '__all__'

class SysDictTypeSerializer(serializers.ModelSerializer):
    ''' 系统字典类型序列化器 '''
    class Meta:
        model = SysDictType
        fields = '__all__'

class SysJobSerializer(serializers.ModelSerializer):
    ''' 系统任务序列化器 '''
    class Meta:
        model = SysJob
        fields = '__all__'

class SysJobLogSerializer(serializers.ModelSerializer):
    ''' 系统任务日志序列化器 '''
    class Meta:
        model = SysJobLog
        fields = '__all__'

class SysLogininforSerializer(serializers.ModelSerializer):
    ''' 系统登录日志序列化器 '''
    class Meta:
        model = SysLogininfor
        fields = '__all__'

class SysMenuSerializer(serializers.ModelSerializer):
    ''' 系统菜单序列化器 '''
    class Meta:
        model = SysMenu
        fields = '__all__'

class SysOperLogSerializer(serializers.ModelSerializer):
    ''' 系统操作日志序列化器 '''
    class Meta:
        model = SysOperLog
        fields = '__all__'

class SysPostSerializer(serializers.ModelSerializer):
    ''' 系统岗位序列化器 '''
    class Meta:
        model = SysPost
        fields = '__all__'

class SysRoleSerializer(serializers.ModelSerializer):
    ''' 系统角色序列化器 '''
    class Meta:
        model = SysRole
        fields = '__all__'

class SysRoleDeptSerializer(serializers.ModelSerializer):
    ''' 系统角色部门序列化器 '''
    class Meta:
        model = SysRoleDept
        fields = '__all__'

class SysRoleMenuSerializer(serializers.ModelSerializer):
    ''' 系统角色菜单序列化器 '''
    class Meta:
        model = SysRoleMenu
        fields = '__all__'

class SysUserPostSerializer(serializers.ModelSerializer):
    ''' 系统用户岗位序列化器 '''
    class Meta:
        model = SysUserPost
        fields = '__all__'